package com.share.tool.mock.model.db;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 触发参数配置
 * </p>
 *
 * @author author
 * @since 2023-11-24
 */
@Data
@Accessors(chain = true)
@TableName("trig_source_conf")
public class SourceConf implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 主键id
     */
    @TableId(type = IdType.AUTO)
    private Long id;
    /**
     * 事件编码
     */
    @TableField(value = "event_code")
    private String eventCode;
    /**
     * 输出参数
     */
    @TableField(value = "event_name")
    private String eventName;
    /**
     * 序号
     */
    @TableField(value = "step_sort")
    private Integer stepSort;
    /**
     * 输出参数
     */
    @TableField(value = "step_name")
    private String stepName;
    /**
     * 步骤
     */
    @TableField(value = "step_code")
    private String stepCode;
    /**
     * 请求方法
     */
    private String method;
    /**
     * json还表单,还是xml,还是form
     */
    @TableField(value = "req_content_type")
    private String reqContentType;
    /**
     * json还表单,还是xml,还是form
     */
    @TableField(value = "resp_content_type")
    private String respContentType;
    @TableField(value = "open_producer")
    private String openProducer;
    @TableField(value = "open_consumer")
    private String openConsumer;
    //关联的接口名字
    @TableField(value = "mock_code")
    private String mockCode;
    /**
     * 是否有效
     */
    private String status;
    /**
     * 请求的接口
     */
    @TableField(value = "api_url")
    private String apiUrl;
    /**
     * 备注
     */
    private String descript;
    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    private Date createTime;


    // 仅仅页面上显示
    @TableField(exist = false)
    private String mockParam;
}
